<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" <?php language_attributes(); ?>>
<head profile="http://gmpg.org/xfn/11">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<?php $options = get_option('iboxs_theme_options'); ?>
<?php if (is_home()):
     $keywords = $options['keywords'];
     $description = $options['description'];
elseif (is_single()):
     if ($post->post_excerpt):
         $description = $post->post_excerpt;
     else:
         $description = substr(strip_tags($post->post_content),0,220);
     endif;
     $keywords = "";      
     $tags = wp_get_post_tags($post->ID);
     foreach ($tags as $tag ):
         $keywords = $keywords . $tag->name . ", ";
     endforeach;
endif;
?>
<meta name="keywords" content="<?php echo $keywords ?>" />
<meta name="description" content="<?php echo $description ?>" />
<title><?php wp_title(' - ', true, 'right'); echo bloginfo('name'); if ($paged > 1) echo ' - Page ', $paged; ?></title>
<link rel="stylesheet" type="text/css" href="<?php bloginfo('stylesheet_url'); ?>" />
<link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>" />
<?php wp_head(); ?>
</head>
<body <?php body_class(); ?>>
<div class="border-w">
<div class="border-n">
<div id="header">
	<div class="wrap cl">
    	 <div id="header_search">
            <?php get_search_form(); ?>
        </div>
        <div class="logo alignleft"><a href="<?php echo home_url(); ?>" title="<?php bloginfo('name'); ?>"><?php bloginfo('name'); ?></a></div>
        <div id="header_nav">
        	<?php wp_nav_menu( array( 'container' => 'none', 'theme_location' => 'primary' ) ); ?>
        </div>
    </div>
</div>
<div id="wrapper" class="wrap">